home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-desktop-9.10-i386-PL.iso / casper / filesystem.squashfs / etc / grub.d / 20_memtest86+ < prev    next >
Text File  |  2009-10-23  |  772b  |  35 lines

  1. #!/bin/sh
  2. set -e
  3.  
  4. prefix=/usr
  5. exec_prefix=${prefix}
  6. libdir=${exec_prefix}/lib
  7.  
  8. # older versions of grub2 do not have this yet (LP: #459080)
  9. if [ ! -e ${libdir}/grub/grub-mkconfig_lib ]; then
  10.     echo "no grub-mkconfig_lib, exiting"
  11.     exit 0
  12. fi
  13.  
  14. . ${libdir}/grub/grub-mkconfig_lib
  15.  
  16. # We can't cope with loop-mounted devices here.
  17. case ${GRUB_DEVICE_BOOT} in
  18.   /dev/loop/*|/dev/loop[0-9])
  19.     exit 0
  20.   ;;
  21. esac
  22.  
  23. if test -e /boot/memtest86+.bin ; then
  24.   MEMTESTPATH=$( make_system_path_relative_to_its_root "/boot/memtest86+.bin" )
  25.   echo "Found memtest86+ image: $MEMTESTPATH" >&2
  26.   cat << EOF
  27. menuentry "Memory test (memtest86+)" {
  28.     linux16    $MEMTESTPATH
  29. }
  30. menuentry "Memory test (memtest86+, serial console 115200)" {
  31.     linux16    $MEMTESTPATH console=ttyS0,115200n8
  32. }
  33. EOF
  34. fi
  35.